from backend.app import create_app
import logging

logging.basicConfig(level=logging.INFO)
logger = logging.getLogger(__name__)

try:
    app = create_app()
except Exception as e:
    logger.error(f"Failed to create app: {str(e)}")
    raise

if __name__ == '__main__':
    # 开发环境下使用debug=True
    app.run(debug=True, host='0.0.0.0', port=5000)
